{extend name="public:base"/}


{block name="title"}编辑店铺{/block}
{block name="style"}{/block}

{block name="main"}

<section class="content" xmlns="http://www.w3.org/1999/html">
    <div class="row">

        <div class="col-md-12">

            <div class="row">
                <div class="col-lg-12">
                    <div class="box">
                        <div class="box-header with-border">
                            <h3 class="box-title">编辑店铺</h3>
                        </div>
                        <form  id="pt_form" method="post">
                            <div class="box-body">

                                <input type="hidden" name="shop_id" value="<?=$model['shop_id']?>" ?>
                                <div class="clearfix"></div>


                                <div class="form-group required">
                                    <div class='col-sm-2 text-right'>
                                        <label for="shop_name" class="control-label Validform_label" >店铺名称</label>
                                    </div>
                                    <div class='col-sm-10'>
                                        <input type="text" id="shop_name" class="form-control" name="shop_name" placeholder="请输入店铺名称" value="<?=$model['shop_name']?>" datatype="s2-50"  errormsg="店铺名称超出长度范围">
                                        <div class="help-block"></div>
                                    </div>
                                </div>

                                <div class="form-group required">
                                    <div class='col-sm-2 text-right'>
                                        <label for="shop_type_id" class="control-label Validform_label" >店铺等级</label>
                                    </div>
                                    <div class='col-sm-10'>
                                        <select id="shop_type_id" class="form-control" name="shop_type_id" datatype="n">
                                            <option>请选择店铺等级</option>
                                            <option value="1" <?=$model['shop_type_id']==1?'selected="selected"':''?>>平台自营</option>
                                            <option value="2" <?=$model['shop_type_id']==2?'selected="selected"':''?>>入驻店铺</option>
                                        </select>
                                        <div class="help-block"></div>
                                    </div>
                                </div>


                                <div class="form-group ">
                                    <div class='col-sm-2 text-right'>
                                        <label for="shop_group_id" class="control-label Validform_label" >店铺分类</label>
                                    </div>
                                    <div class='col-sm-10'>
                                        <select name="shop_group_id" datatype="*" class="form-control">
                                            <option value="">请选择</option>
                                            <?php if(!empty($shop_group)){ foreach($shop_group as $k=>$v){?>
                                            <option  <?=$model['shop_group_id'] == $v['id']?'selected="selected"':''?> value="<?=$v['id']?>"><?=$v['group_name']?></option>
                                            <?php }}?>
                                        </select>

                                        <div class="help-block"></div>
                                    </div>
                                </div>



                                <div class="form-group required">
                                    <div class="col-sm-2 text-right">
                                        <label class="control-label Validform_label">店铺状态                                        </label>
                                    </div>

                                    <div class="col-sm-10">
                                        <div>

                                            <span style="color:#636f7a"><input type="radio" name="shop_status" value="0" datatype="*"  nullmsg="请选择店铺状态">关闭</span>


                                            <span style="color:#636f7a"><input type="radio" name="shop_status" value="1" checked="checked">开启</span>

                                                                                    </div>
                                        <div class="help-block"></div>
                                    </div>
                                </div>



                                <div class="form-group ">
                                    <div class='col-sm-2 text-right'>
                                        <label for="shop_close_info" class="control-label Validform_label" >店铺关闭原因</label>
                                    </div>
                                    <div class='col-sm-10'>
                                        <input type="text" id="shop_close_info" class="form-control" name="shop_close_info" placeholder="请输入店铺关闭原因,开启不用填写" value="<?=$model['shop_close_info']?>" datatype="s2-255" ignore="ignore"  errormsg="店铺关闭原因超出长度范围">
                                        <div class="help-block"></div>
                                    </div>
                                </div>

                                <div class="form-group ">
                                    <div class='col-sm-2 text-right'>
                                        <label for="shop_sort" class="control-label Validform_label" >店铺排序</label>
                                    </div>
                                    <div class='col-sm-10'>
                                        <input type="text" id="shop_sort" class="form-control" name="shop_sort" placeholder="请输入店铺排序" value="<?=$model['shop_sort']?>" datatype="n" ignore="ignore"  errormsg="店铺排序是数字类型">
                                        <div class="help-block"></div>
                                    </div>
                                </div>



                                <div class="form-group ">
                                    <div class='col-sm-2 text-right'>
                                        <label for="shop_credit" class="control-label Validform_label" >店铺信用评分</label>
                                    </div>
                                    <div class='col-sm-10'>
                                        <input type="text" id="shop_credit" class="form-control" name="shop_credit" placeholder="请输入店铺信用评分,1-5之间的数字" value="<?=$model['shop_credit']?>" datatype="n" ignore="ignore"  errormsg="店铺信用评分是数字类型">
                                        <div class="help-block"></div>
                                    </div>
                                </div>

                                <div class="form-group ">
                                    <div class="col-sm-2 text-right">
                                        <label class="control-label Validform_label">描述相符度分数                                        </label>
                                    </div>

                                    <div class="col-sm-10">
                                        <div>
                                            <input type="text" id="shop_desccredit" class="form-control" name="shop_desccredit" placeholder="请输入描述相符度分数 ,1-5之间的数字" value="<?=$model['shop_desccredit']?>" datatype="n" ignore="ignore"  errormsg="描述相符度是数字类型">
                                        </div>
                                        <div class="help-block"></div>
                                    </div>
                                </div>

                                <div class="form-group ">
                                    <div class="col-sm-2 text-right">
                                        <label class="control-label Validform_label">服务态度分数                                        </label>
                                    </div>

                                    <div class="col-sm-10">
                                        <div>
                                            <input type="text" id="shop_servicecredit" class="form-control" name="shop_servicecredit" placeholder="请输入服务态度分数 ,1-5之间的数字" value="<?=$model['shop_servicecredit']?>" datatype="n" ignore="ignore"  errormsg="服务态度分数是数字类型">
                                        </div>
                                        <div class="help-block"></div>
                                    </div>
                                </div>


                                <div class="form-group ">
                                    <div class="col-sm-2 text-right">
                                        <label class="control-label Validform_label">发货速度分数                                        </label>
                                    </div>

                                    <div class="col-sm-10">
                                        <div>
                                            <input type="text" id="shop_deliverycredit" class="form-control" name="shop_deliverycredit" placeholder="请输入发货速度分数 ,1-5之间的数字" value="<?=$model['shop_deliverycredit']?>" datatype="n" ignore="ignore"  errormsg="发货速度分数是数字类型">
                                        </div>
                                        <div class="help-block"></div>
                                    </div>
                                </div>

                                <div class="form-group ">
                                    <div class='col-sm-2 text-right'>
                                        <label for="shop_platform_commission_rate" class="control-label Validform_label" >平台抽取佣金比率</label>
                                    </div>
                                    <div class='col-sm-10'>
                                        <input type="text" id="shop_platform_commission_rate" class="form-control" name="shop_platform_commission_rate" placeholder="请输入平台抽取比率百分比" value="<?=$model['shop_platform_commission_rate']?>" datatype="n" ignore="ignore">
                                        <div class="help-block"></div>
                                    </div>
                                </div>
                                 </div>
                            <div class="box-footer text-center">
                                <button class="btn btn-primary" type="submit">保存</button>
                                <span class="btn btn-white" onclick="history.go(-1)">返回</span>
                            </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </div>
</section>
{/block}

{block name="js"}
<script>

    var validate = validator('#pt_form');
    
</script>
{/block}